<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        *{
            margin-top: 20px;
        }
        .box1{
            width: 200px;
            height: 20px;
            background-color: #ddd;
            position: relative;
        }
        .box2{
            width: 200px;
            height: 20px;
            position: relative;
            /* border-radius: 20px; */
            /* border: 1px solid #000; */
        }
        .box3{
            width: 200px;
            height: 20px;
            border-radius: 20px;
            background-image:repeating-linear-gradient(135deg,#fff 0px,#ddd 10px,grey 0px,#fff 20px);
            position: relative;
        }
        .one{
            width: 200px;
            height: 20px;
            animation: one 4s linear infinite;
            
        }
        .two{
            width: 200px;
            height: 20px;
            border-radius: 20px;
            animation:two 2s linear infinite;
            
        }
        .three{
            width: 200px;
            height: 20px;
            border-radius: 20px;
            animation: three 4s linear infinite;
            
        }
        .four {
            width: 100px;
            height: 20px;
            background: repeating-linear-gradient(to right, #000 0 15px, #fff 0 20px) 0/0% no-repeat, repeating-linear-gradient(to right, #dbdbdb 0 15px, #fff 0 20px) 0/100%;
            animation: four 3s steps(6) infinite;
        }

        @keyframes four {
            100% {
                background-size: 120%;
            }
        }
        @keyframes one{
            0% {
                width: 10px;
                background-color: black;
            }
            100% {
               
                background-color: black;
            }
        }
        @keyframes two{
            0% {
                width: 10px;
                background-image: linear-gradient(to right,pink,skyblue);
            }
            100% {
               
                background-image: linear-gradient(to right,pink,skyblue);
            }
        }
        @keyframes three{
            0% {
                width: 10px;
                background-image:repeating-linear-gradient(135deg,yellow 20px,red 50px);
            }
            100% {
               
                background-image:repeating-linear-gradient(135deg,yellow 20px,red 50px);
            }
        }
    </style>
</head>
<body>
    <div class="box1">
        <div class="one"></div>
    </div>
    <div class="box2">
        <div class="two"></div>
    </div>
    <div class="box3">
        <div class="three"></div>
    </div>
    <div class="box4">
        <div class="four"></div>
    </div>
</body>
</html>